package com.aaa.a1107.demo01;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;

/**
 * @author 荆豪峰
 * @version 1.0
 */
public class Test01 {
    public static void main(String[] args) {
        LocalDateTime now = LocalDateTime.now();
        System.out.println("转化前的日期："+now);
        DateTimeFormatter dateTimeFormatter = DateTimeFormatter.ofPattern("yyyy/MM/dd HH:mm:ss");
        String format =  now.format(dateTimeFormatter);
        System.out.println("转化后的日期："+format);
    }
}
